<template>
	<view>
		<view class="header">
			<image class="user_picture" src="/static/logo.png"></image>
			<view class="user_name_forks">
				<view class="">用户昵称</view>
				<view class="fan_fork_likes">
						<view>
							<view>
								3
							</view>
							<view>
								粉丝
							</view>
						</view>
						<view>
							<view>
								3
							</view>
							<view>
								关注
							</view>
						</view>
						<view>
							<view>
								3
							</view>
							<view>
								获赞
							</view>
						</view>
				</view>
				<view class="forks_button" v-if="!CheckIfSelf">+关注</view>
				<view class="forks_button" v-if="CheckIfSelf" @click="ToChangeInformation">编辑资料</view>
			</view>
		</view>
		<UserInformation :ifChange="true"></UserInformation>
		<view class="team_title">帖子</view>
		<TeamList v-for="item in items" :team_information="item" :key="item.id"></TeamList>
	</view>
</template>

<script>
	import UserInformation from "@/components/UserInformation.vue"
	import TeamList from "@/components/TeamList.vue"
	
	export default {
		onload(){
		},
		data() {
			return {
				items:[{
					'id':'1',
					'imgurl':'123',
					'name':'拼车组队',
					'leader':'甲乙丙丁',
					'process':'3/5',
					'time':'2020',
					"teamid":1
				},{
					'id':'2',
					'imgurl':'123',
					'name':'拼车组队',
					'leader':'甲乙丙丁',
					'process':'3/5',
					'time':'2020'
				}],
				CheckIfSelf:0
			}
		},
		components:{
			UserInformation,
			TeamList
		},
		methods: {
			ToChangeInformation(){
				uni.navigateTo({
					url:'/pages/user_information_change/user_information_change'
				})
			}
		}
	}
</script>

<style>
.header{
	display: flex;
	margin: 20rpx 0 20rpx 0;
}
.header image{
	margin-left: 50rpx;
	width: 225rpx;
	height: 225rpx;
}
.user_name_forks{
	margin-left: 50rpx;
	margin-right: auto;
}
.fan_fork_likes{
	margin-top: 10rpx;
	display: flex;
	flex-direction: row;
	width: 400rpx;
	text-align: center;
}
.fan_fork_likes view{
	margin-left: 10rpx;
}
.forks_button{
	background-color: #93C6EC;
	border-radius: 50rpx;
	text-align: center;
	line-height: 80rpx;
	height: 80rpx;
}
.team_title{
	margin:20rpx 0 10rpx 40rpx;
}
</style>
